home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 14 / CU Amiga Magazine's Super CD-ROM 14 (1997)(EMAP Images)(GB)(Track 1 of 3)[!][issue 1997-09].iso / CUCD / Programming / IEditor / ARexx / MoveImage.ie < prev    next >
Text File  |  1997-06-17  |  799b  |  40 lines

  1. /*
  2.    $VER: MoveImage.ie 1.1 (2.2.96) © Simone Tellini
  3. */
  4.  
  5. address 'IEDITOR.1'
  6. options results
  7. options failat 6  /* ignore warnings */
  8.  
  9. 'GETIMAGE'
  10. if RC = 5 then exit  /* user aborted */
  11. which = result
  12.  
  13. /* close standard I/O channels (if IE started from CLI, this lets
  14.    the output to be redirected where I want) */
  15.  
  16. call close 'STDOUT'
  17. call close 'STDIN'
  18.  
  19. /* open a window for dos I/O on IEditor's screen */
  20.  
  21. call open 'STDOUT','CON:100/10/510/200/Interface Editor - ©1994-1996 Simone Tellini/SCREEN IEDITOR.1'
  22. call pragma '*','STDOUT'
  23. call open 'STDIN','*'
  24.  
  25. /* ask the coordinates */
  26.  
  27. say 'Enter the new coordinates:'
  28. parse pull newx newy
  29.  
  30. /* close the window */
  31.  
  32. call close 'STDIN'
  33. call close 'STDOUT'
  34.  
  35. /* set the new position */
  36.  
  37. 'SETIMAGEATTR IMAGE' which 'LEFTEDGE' newx 'TOPEDGE' newy
  38.  
  39. exit
  40.